<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + path + "/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<link type="text/css" rel="stylesheet" href="<%=basePath%>statics/js/plug/jbox/jBox.css"/>
<script type="text/javascript" src="<%=basePath %>statics/js/plug/jquery.validate.js"></script>
<script type="text/javascript" src="<%=basePath%>/statics/js/plug/jbox/jBox.js"></script>
<script type="text/javascript" src="<%=basePath%>/statics/js/base/basemenu/base_menu_edit.js"></script>
<div class="table_edit_div" style="display: block">
	<form id="updateForm">
		<input id="updateId" name="id" type="hidden" value="${baseMenu.id}">
	    <table border="0">
	   		<tr>
	             <td class="attr" style="vertical-align:top;width: 70px;"><span>菜单名称：</span></td>
	             <td style="vertical-align:top;width: 310px;min-width: 310px;"><input id="labelEdit" type="text" name="label" value="${baseMenu.label}"/>
	             <img alt="" src="<%=basePath %>statics/images/common/star.gif" width="9" height="10">
	             </td>
	             <td class="attr" style="vertical-align:top;width: 80px;"><span>操作权限：</span></td>
	             <td style="vertical-align:top;">
	             	<input type="text" id="operateAuthorityEdit" name="authority" value="${operateAuthorityName}" readonly/>
	             	<input type="hidden" id="operateAuthorityIdEdit" name="operateAuthorityIds" value="${operateAuthorityId}"/>
	             	<input type="hidden" id="operateAuthorityIdEditCopy" name="operateAuthorityIdsReserve" value="${operateAuthorityId}"/>
	             </td>
	       	</tr>
	        <tr>
	             <td class="attr" style="vertical-align:top;"><span>所属父类：</span></td>
	             <td style="vertical-align:top;">
	             	<c:if test="${baseMenu.parentId==0 }">
		             	<input type="text" id="menuParentNameEdit" name="menuParentName" value="无" readonly/>
		             	<input type="hidden" id="parentIdEdit" name="parentId" value="0" />
	             	</c:if>
	             	<c:if test="${baseMenu.parentId!=0 }">
		             	<input type="text" id="menuParentNameEdit" name="menuParentName" value="${parentMenu.label}" readonly/>
		             	<input type="hidden" id="parentIdEdit" name="parentId" value="${baseMenu.parentId}" />
	             	</c:if>
	             	<img alt="" src="<%=basePath %>statics/images/common/star.gif" width="9" height="10">
	             </td>
	             <td class="attr" style="width: 80px;"><span>关键字：</span></td>
	             <td>
	       			<input id="editSearchName" type="text"/>&nbsp;
	         		<button type="button"  onclick="search_ztree('operateAuthorityTreeEdit','editSearchName')">查询</button>
	             </td>
	             
	         </tr>
	         <tr>
	         	<td class="attr" style="vertical-align:top;"><span>查看权限：</span></td>
	         	<td style="vertical-align:top;">
	         		<input type="text" id="menuLookAuthorityEdit" name="menuLookAuthorityEdit" value="${menuLookAuthority.name}" readonly/>
	             	<input type="hidden" id="menuLookAuthorityIdEdit" name="authorityId" value="${menuLookAuthority.id}"/>
	             	<img alt="" src="<%=basePath %>statics/images/common/star.gif" width="9" height="10">
	         	</td>
	         	<td rowspan="7" colspan="2" style="padding-left: 80px;">
	             	<div class="tree" style="width: 290px; overflow-y: auto; overflow-x: hidden; height: 360px;">
	             		<ul id="operateAuthorityTreeEdit" class="ztree"></ul>
	             	</div>
	             </td>
	         </tr>
	         <tr>
	             <td class="attr" style="vertical-align:top;"><span>菜单样式：</span></td>
	             <td style="vertical-align:top;"><input id="classNameEdit" type="text" name="className" value="${baseMenu.className}">
	            <%--  <img alt="" src="<%=basePath %>statics/images/common/star.gif" width="9" height="10"> --%>
	             </td>
	         </tr>
	         <tr id="urlEditTr">
	             <td class="attr" style="vertical-align:top;"><span>菜单链接：</span></td>
	             <td style="vertical-align:top;">
	             	<input id="urlEdit" type="text" name="url" value="${baseMenu.url}">
	             	<input id="urlEditReserve" type="hidden" name="urlEditReserve" />
	             </td>
	         </tr>
	         <tr>
	             <td class="attr" style="vertical-align:top;"><span>菜单高度：</span></td>
	             <td style="vertical-align:top;"><input id="controlHeightEdit" type="text" name="controlHeight" value="${baseMenu.controlHeight}">
	             <img alt="" src="<%=basePath %>statics/images/common/star.gif" width="9" height="10">
	             </td>
	         </tr>
			<tr>
				<td class="attr" style="vertical-align:top;"><span>加载方式：</span></td>
				<td style="vertical-align:top;">
					<input name="loadMethod" type="radio" value="1" ${baseMenu.loadMethod==1 ? 'checked' : ''}>覆盖
					<input name="loadMethod" type="radio" value="2" ${baseMenu.loadMethod==2 ? 'checked' : ''}>叠加
					<img alt="" src="<%=basePath %>statics/images/common/star.gif" width="9" height="10">
				</td>
			</tr>
	         <tr>
	             <td class="attr" style="vertical-align:top;"><span>菜单序号：</span></td>
	             <td style="vertical-align:top;"><input id="sortFlagEdit" type="text" name="sortFlag" value="${baseMenu.sortFlag}">
	             <img alt="" src="<%=basePath %>statics/images/common/star.gif" width="9" height="10">
	             </td>
	         </tr>
	          <tr style=" height:100px;">
	             <td class="attr" style="vertical-align:top;"><span>备&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;注：</span></td>
	             <td height="100px" style="vertical-align:top;"><textarea id="remarkEdit" name="remark" cols="35" rows="5" style="width: 292px;height: 100px;">${baseMenu.remark}</textarea></td>
	         </tr>
	    </table>
	    <div style="width: 100%;margin: 0 auto;">
       <ul style="width: 50%;margin: 0 auto;">
       	<li style="float: left;margin-right: 80px;">
	    <div style="text-align: center;margin-top: 20px;">
	        <input type="submit" value="更新" style="margin-top: 6px">
	    </div>
	    </li>  
	    <li style="float: left;margin-right: 80px;">
	    <div style="text-align: center;margin-top: 20px;">
	        <input type="button" value="取消" onclick="heavyLoad();" style="margin-top: 6px">
	    </div>
	    </li>
       	<li style="float: left;">
	       <div style="text-align: center;margin-top: 20px;">
	            <input type="button" value="删除" onclick="deleteMenu();" style="margin-top: 6px">
	       </div>
	    </li>

       </ul>
       </div>
	</form>
</div>